package com.example.repository;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import com.example.domain.Girl;

public interface GirlRepository extends JpaRepository<Girl, Integer>{

//	通过年龄查询
	public List<Girl> findByAge(Integer age);
	
	@Query(value="select count(1) from girl" ,nativeQuery=true)
	public Integer girlCount(); 
}
